import '@/assets/main.css'
import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import pinia from '@/stores/index'
import * as ElementPlusIconsVue from '@element-plus/icons-vue'
import '@/iconfont/iconfont.css'
import '@/iconfont/iconfont.js'
import directives from './directives'
// elementplus国际化配置
import ElementPlus from 'element-plus'
import zhCn from 'element-plus/es/locale/lang/zh-cn'
import 'dayjs/locale/zh-cn';


const app = createApp(App)
app.use(pinia)
app.use(router)
for (const [key, component] of Object.entries(ElementPlusIconsVue)) {
  app.component(key, component)
}
app.use(directives)
app.use(ElementPlus, {
  locale: zhCn,
})
import "tailwindcss/tailwind.css";
//代码高亮
import hljs from 'highlight.js'
import 'highlight.js/styles/atom-one-dark.css'
import javascript from 'highlight.js/lib/languages/javascript';
import hljsVuePlugin from "@highlightjs/vue-plugin";
hljs.registerLanguage('javascript', javascript);
app.use(hljsVuePlugin)

window.router = router
app.mount('#app')
